package com.heima.domain.po;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Builder;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;

/**
 * <p>
 * </p>
 * @author shenkunlin
 * @since 2024-07-12
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Builder
@Accessors(chain = true)
@TableName("item_freeze")
public class ItemFreeze implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "xid", type = IdType.INPUT)
    private String xid;

    /***
     * 冻结数量【JSON结构】  [{"itemId":5,"num":2},{"itemId":2,"num":3}]
     */
    private String freezeCount;

    private Integer state;

    public static abstract class State {
        public final static int TRY = 0;
        public final static int CONFIRM = 1;
        public final static int CANCEL = 2;
    }
}
